using HKB.Common;
using System;
using System.CodeDom.Compiler;
using System.ComponentModel;
using System.ComponentModel.Design;
using System.Data;
using System.Data.Common;
using System.Data.SqlClient;
using System.Diagnostics;
namespace HKB.Data.Dal.S_VIPCardTableAdapters
{
	[GeneratedCode("System.Data.Design.TypedDataSetGenerator", "2.0.0.0"), DataObject(true), HelpKeyword("vs.data.TableAdapter"), Designer("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"), DesignerCategory("code"), ToolboxItem(true)]
	public class HLShop_VIPCardTableAdapter : Component
	{
		private SqlDataAdapter _adapter;
		private SqlConnection _connection;
		private SqlCommand[] _commandCollection;
		private bool _clearBeforeFill;
		[System.Diagnostics.DebuggerNonUserCode]
		private SqlDataAdapter Adapter
		{
			get
			{
				if (this._adapter == null)
				{
					this.InitAdapter();
				}
				return this._adapter;
			}
		}
		[System.Diagnostics.DebuggerNonUserCode]
		internal SqlConnection Connection
		{
			get
			{
				if (this._connection == null)
				{
					this.InitConnection();
				}
				return this._connection;
			}
			set
			{
				this._connection = value;
				if (this.Adapter.InsertCommand != null)
				{
					this.Adapter.InsertCommand.Connection = value;
				}
				if (this.Adapter.DeleteCommand != null)
				{
					this.Adapter.DeleteCommand.Connection = value;
				}
				if (this.Adapter.UpdateCommand != null)
				{
					this.Adapter.UpdateCommand.Connection = value;
				}
				for (int i = 0; i < this.CommandCollection.Length; i++)
				{
					if (this.CommandCollection[i] != null)
					{
						this.CommandCollection[i].Connection = value;
					}
				}
			}
		}
		[System.Diagnostics.DebuggerNonUserCode]
		protected SqlCommand[] CommandCollection
		{
			get
			{
				if (this._commandCollection == null)
				{
					this.InitCommandCollection();
				}
				return this._commandCollection;
			}
		}
		[System.Diagnostics.DebuggerNonUserCode]
		public bool ClearBeforeFill
		{
			get
			{
				return this._clearBeforeFill;
			}
			set
			{
				this._clearBeforeFill = value;
			}
		}
		[System.Diagnostics.DebuggerNonUserCode]
		public HLShop_VIPCardTableAdapter()
		{
			this.ClearBeforeFill = true;
		}
		[System.Diagnostics.DebuggerNonUserCode]
		private void InitAdapter()
		{
			this._adapter = new SqlDataAdapter();
			DataTableMapping dataTableMapping = new DataTableMapping();
			dataTableMapping.SourceTable = "Table";
			dataTableMapping.DataSetTable = "HLShop_VIPCard";
			dataTableMapping.ColumnMappings.Add("Card_ID", "Card_ID");
			dataTableMapping.ColumnMappings.Add("ShopID", "ShopID");
			dataTableMapping.ColumnMappings.Add("Isupgrade", "Isupgrade");
			dataTableMapping.ColumnMappings.Add("Status", "Status");
			dataTableMapping.ColumnMappings.Add("PresentPoint1", "PresentPoint1");
			dataTableMapping.ColumnMappings.Add("TransCount1", "TransCount1");
			dataTableMapping.ColumnMappings.Add("TransMoney1", "TransMoney1");
			dataTableMapping.ColumnMappings.Add("PresentExp1", "PresentExp1");
			dataTableMapping.ColumnMappings.Add("PresentPoint2", "PresentPoint2");
			dataTableMapping.ColumnMappings.Add("TransCount2", "TransCount2");
			dataTableMapping.ColumnMappings.Add("TransMoney2", "TransMoney2");
			dataTableMapping.ColumnMappings.Add("PresentExp2", "PresentExp2");
			dataTableMapping.ColumnMappings.Add("GiveDiscount2", "GiveDiscount2");
			dataTableMapping.ColumnMappings.Add("GivePoint2", "GivePoint2");
			dataTableMapping.ColumnMappings.Add("GiveMoney2", "GiveMoney2");
			dataTableMapping.ColumnMappings.Add("GiveDiscount1", "GiveDiscount1");
			dataTableMapping.ColumnMappings.Add("GivePoint1", "GivePoint1");
			dataTableMapping.ColumnMappings.Add("GiveMoney1", "GiveMoney1");
			dataTableMapping.ColumnMappings.Add("GiveDiscount3", "GiveDiscount3");
			dataTableMapping.ColumnMappings.Add("GivePoint3", "GivePoint3");
			dataTableMapping.ColumnMappings.Add("GiveMoney3", "GiveMoney3");
			dataTableMapping.ColumnMappings.Add("GiveDiscount4", "GiveDiscount4");
			dataTableMapping.ColumnMappings.Add("GivePoint4", "GivePoint4");
			dataTableMapping.ColumnMappings.Add("GiveMoney4", "GiveMoney4");
			dataTableMapping.ColumnMappings.Add("GiveExp1", "GiveExp1");
			dataTableMapping.ColumnMappings.Add("GiveExp2", "GiveExp2");
			dataTableMapping.ColumnMappings.Add("GiveExp3", "GiveExp3");
			dataTableMapping.ColumnMappings.Add("GiveExp4", "GiveExp4");
			this._adapter.TableMappings.Add(dataTableMapping);
			this._adapter.DeleteCommand = new SqlCommand();
			this._adapter.DeleteCommand.Connection = this.Connection;
			this._adapter.DeleteCommand.CommandText = "DELETE FROM [HLShop_VIPCard] WHERE (([Card_ID] = @Original_Card_ID))";
			this._adapter.DeleteCommand.CommandType = CommandType.Text;
			this._adapter.DeleteCommand.Parameters.Add(new SqlParameter("@Original_Card_ID", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "Card_ID", DataRowVersion.Original, false, null, "", "", ""));
			this._adapter.InsertCommand = new SqlCommand();
			this._adapter.InsertCommand.Connection = this.Connection;
			this._adapter.InsertCommand.CommandText = "INSERT INTO [HLShop_VIPCard] ([ShopID], [Isupgrade], [Status], [PresentPoint1], [TransCount1], [TransMoney1], [PresentExp1], [GiveDiscount1], [GivePoint1], [GiveMoney1], [PresentPoint2], [TransCount2], [TransMoney2], [PresentExp2], [GiveDiscount2], [GivePoint2], [GiveMoney2], [GiveDiscount3], [GivePoint3], [GiveMoney3], [GiveDiscount4], [GivePoint4], [GiveMoney4], [GiveExp1], [GiveExp2], [GiveExp3], [GiveExp4]) VALUES (@ShopID, @Isupgrade, @Status, @PresentPoint1, @TransCount1, @TransMoney1, @PresentExp1, @GiveDiscount1, @GivePoint1, @GiveMoney1, @PresentPoint2, @TransCount2, @TransMoney2, @PresentExp2, @GiveDiscount2, @GivePoint2, @GiveMoney2, @GiveDiscount3, @GivePoint3, @GiveMoney3, @GiveDiscount4, @GivePoint4, @GiveMoney4, @GiveExp1, @GiveExp2, @GiveExp3, @GiveExp4)";
			this._adapter.InsertCommand.CommandType = CommandType.Text;
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@ShopID", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "ShopID", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@Isupgrade", SqlDbType.Bit, 0, ParameterDirection.Input, 0, 0, "Isupgrade", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@Status", SqlDbType.Bit, 0, ParameterDirection.Input, 0, 0, "Status", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@PresentPoint1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "PresentPoint1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@TransCount1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "TransCount1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@TransMoney1", SqlDbType.Decimal, 0, ParameterDirection.Input, 18, 2, "TransMoney1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@PresentExp1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "PresentExp1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveDiscount1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveDiscount1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GivePoint1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GivePoint1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveMoney1", SqlDbType.Decimal, 0, ParameterDirection.Input, 18, 0, "GiveMoney1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@PresentPoint2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "PresentPoint2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@TransCount2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "TransCount2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@TransMoney2", SqlDbType.Decimal, 0, ParameterDirection.Input, 18, 2, "TransMoney2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@PresentExp2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "PresentExp2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveDiscount2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveDiscount2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GivePoint2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GivePoint2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveMoney2", SqlDbType.Decimal, 0, ParameterDirection.Input, 10, 0, "GiveMoney2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveDiscount3", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveDiscount3", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GivePoint3", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GivePoint3", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveMoney3", SqlDbType.Decimal, 0, ParameterDirection.Input, 10, 0, "GiveMoney3", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveDiscount4", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveDiscount4", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GivePoint4", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GivePoint4", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveMoney4", SqlDbType.Decimal, 0, ParameterDirection.Input, 10, 0, "GiveMoney4", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveExp1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveExp1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveExp2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveExp2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveExp3", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveExp3", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.InsertCommand.Parameters.Add(new SqlParameter("@GiveExp4", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveExp4", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand = new SqlCommand();
			this._adapter.UpdateCommand.Connection = this.Connection;
			this._adapter.UpdateCommand.CommandText = "UPDATE [HLShop_VIPCard] SET [ShopID] = @ShopID, [Isupgrade] = @Isupgrade, [Status] = @Status, [PresentPoint1] = @PresentPoint1, [TransCount1] = @TransCount1, [TransMoney1] = @TransMoney1, [PresentExp1] = @PresentExp1, [GiveDiscount1] = @GiveDiscount1, [GivePoint1] = @GivePoint1, [GiveMoney1] = @GiveMoney1, [PresentPoint2] = @PresentPoint2, [TransCount2] = @TransCount2, [TransMoney2] = @TransMoney2, [PresentExp2] = @PresentExp2, [GiveDiscount2] = @GiveDiscount2, [GivePoint2] = @GivePoint2, [GiveMoney2] = @GiveMoney2, [GiveDiscount3] = @GiveDiscount3, [GivePoint3] = @GivePoint3, [GiveMoney3] = @GiveMoney3, [GiveDiscount4] = @GiveDiscount4, [GivePoint4] = @GivePoint4, [GiveMoney4] = @GiveMoney4, [GiveExp1] = @GiveExp1, [GiveExp2] = @GiveExp2, [GiveExp3] = @GiveExp3, [GiveExp4] = @GiveExp4 WHERE (([Card_ID] = @Original_Card_ID))";
			this._adapter.UpdateCommand.CommandType = CommandType.Text;
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@ShopID", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "ShopID", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@Isupgrade", SqlDbType.Bit, 0, ParameterDirection.Input, 0, 0, "Isupgrade", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@Status", SqlDbType.Bit, 0, ParameterDirection.Input, 0, 0, "Status", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@PresentPoint1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "PresentPoint1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@TransCount1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "TransCount1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@TransMoney1", SqlDbType.Decimal, 0, ParameterDirection.Input, 18, 2, "TransMoney1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@PresentExp1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "PresentExp1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveDiscount1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveDiscount1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GivePoint1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GivePoint1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveMoney1", SqlDbType.Decimal, 0, ParameterDirection.Input, 18, 0, "GiveMoney1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@PresentPoint2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "PresentPoint2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@TransCount2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "TransCount2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@TransMoney2", SqlDbType.Decimal, 0, ParameterDirection.Input, 18, 2, "TransMoney2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@PresentExp2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "PresentExp2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveDiscount2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveDiscount2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GivePoint2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GivePoint2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveMoney2", SqlDbType.Decimal, 0, ParameterDirection.Input, 10, 0, "GiveMoney2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveDiscount3", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveDiscount3", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GivePoint3", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GivePoint3", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveMoney3", SqlDbType.Decimal, 0, ParameterDirection.Input, 10, 0, "GiveMoney3", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveDiscount4", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveDiscount4", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GivePoint4", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GivePoint4", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveMoney4", SqlDbType.Decimal, 0, ParameterDirection.Input, 10, 0, "GiveMoney4", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveExp1", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveExp1", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveExp2", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveExp2", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveExp3", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveExp3", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@GiveExp4", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "GiveExp4", DataRowVersion.Current, false, null, "", "", ""));
			this._adapter.UpdateCommand.Parameters.Add(new SqlParameter("@Original_Card_ID", SqlDbType.Int, 0, ParameterDirection.Input, 0, 0, "Card_ID", DataRowVersion.Original, false, null, "", "", ""));
		}
		[System.Diagnostics.DebuggerNonUserCode]
		private void InitConnection()
		{
			this._connection = new SqlConnection();
			this._connection.ConnectionString = Conn.CurrenConnectionStrings;
		}
		[System.Diagnostics.DebuggerNonUserCode]
		private void InitCommandCollection()
		{
			this._commandCollection = new SqlCommand[6];
			this._commandCollection[0] = new SqlCommand();
			this._commandCollection[0].Connection = this.Connection;
			this._commandCollection[0].CommandText = "SELECT     *\r\nFROM         HLShop_VIPCard";
			this._commandCollection[0].CommandType = CommandType.Text;
			this._commandCollection[1] = new SqlCommand();
			this._commandCollection[1].Connection = this.Connection;
			this._commandCollection[1].CommandText = "DELETE FROM HLShop_VIPCard\r\nWHERE (Card_ID = @card_id)";
			this._commandCollection[1].CommandType = CommandType.Text;
			this._commandCollection[1].Parameters.Add(new SqlParameter("@card_id", SqlDbType.Int, 4, ParameterDirection.Input, 0, 0, "Card_ID", DataRowVersion.Original, false, null, "", "", ""));
			this._commandCollection[2] = new SqlCommand();
			this._commandCollection[2].Connection = this.Connection;
			this._commandCollection[2].CommandText = "SELECT Card_ID, GiveDiscount1, GiveDiscount2, GiveDiscount3, GiveDiscount4, GiveExp1, GiveExp2, GiveExp3, GiveExp4, GiveMoney1, GiveMoney2, GiveMoney3, GiveMoney4, GivePoint1, GivePoint2, GivePoint3, GivePoint4, Isupgrade, PresentExp1, PresentExp2, PresentPoint1, PresentPoint2, ShopID, Status, TransCount1, TransCount2, TransMoney1, TransMoney2 FROM HLShop_VIPCard WHERE (Card_ID = @CardID)";
			this._commandCollection[2].CommandType = CommandType.Text;
			this._commandCollection[2].Parameters.Add(new SqlParameter("@CardID", SqlDbType.Int, 4, ParameterDirection.Input, 0, 0, "Card_ID", DataRowVersion.Current, false, null, "", "", ""));
			this._commandCollection[3] = new SqlCommand();
			this._commandCollection[3].Connection = this.Connection;
			this._commandCollection[3].CommandText = "SELECT Card_ID, GiveDiscount1, GiveDiscount2, GiveDiscount3, GiveDiscount4, GiveExp1, GiveExp2, GiveExp3, GiveExp4, GiveMoney1, GiveMoney2, GiveMoney3, GiveMoney4, GivePoint1, GivePoint2, GivePoint3, GivePoint4, Isupgrade, PresentExp1, PresentExp2, PresentPoint1, PresentPoint2, ShopID, Status, TransCount1, TransCount2, TransMoney1, TransMoney2 FROM HLShop_VIPCard WHERE (ShopID IN (SELECT ShopID FROM HLShop_Shop WHERE (ShopOwnerID = @ShopOwnerID)))";
			this._commandCollection[3].CommandType = CommandType.Text;
			this._commandCollection[3].Parameters.Add(new SqlParameter("@ShopOwnerID", SqlDbType.Int, 4, ParameterDirection.Input, 0, 0, "", DataRowVersion.Current, false, null, "", "", ""));
			this._commandCollection[4] = new SqlCommand();
			this._commandCollection[4].Connection = this.Connection;
			this._commandCollection[4].CommandText = "SELECT Card_ID, GiveDiscount1, GiveDiscount2, GiveDiscount3, GiveDiscount4, GiveExp1, GiveExp2, GiveExp3, GiveExp4, GiveMoney1, GiveMoney2, GiveMoney3, GiveMoney4, GivePoint1, GivePoint2, GivePoint3, GivePoint4, Isupgrade, PresentExp1, PresentExp2, PresentPoint1, PresentPoint2, ShopID, Status, TransCount1, TransCount2, TransMoney1, TransMoney2 FROM HLShop_VIPCard WHERE (ShopID = @ShopID)";
			this._commandCollection[4].CommandType = CommandType.Text;
			this._commandCollection[4].Parameters.Add(new SqlParameter("@ShopID", SqlDbType.Int, 4, ParameterDirection.Input, 0, 0, "ShopID", DataRowVersion.Current, false, null, "", "", ""));
			this._commandCollection[5] = new SqlCommand();
			this._commandCollection[5].Connection = this.Connection;
			this._commandCollection[5].CommandText = "PR_GetVIPCard";
			this._commandCollection[5].CommandType = CommandType.StoredProcedure;
			this._commandCollection[5].Parameters.Add(new SqlParameter("@RETURN_VALUE", SqlDbType.Int, 4, ParameterDirection.ReturnValue, 10, 0, null, DataRowVersion.Current, false, null, "", "", ""));
			this._commandCollection[5].Parameters.Add(new SqlParameter("@username", SqlDbType.VarChar, 50, ParameterDirection.Input, 0, 0, null, DataRowVersion.Current, false, null, "", "", ""));
			this._commandCollection[5].Parameters.Add(new SqlParameter("@shopname", SqlDbType.VarChar, 50, ParameterDirection.Input, 0, 0, null, DataRowVersion.Current, false, null, "", "", ""));
		}
		[DataObjectMethod(DataObjectMethodType.Select, true), HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual S_VIPCard.HLShop_VIPCardDataTable GetAllVIPCard()
		{
			this.Adapter.SelectCommand = this.CommandCollection[0];
			S_VIPCard.HLShop_VIPCardDataTable hLShop_VIPCardDataTable = new S_VIPCard.HLShop_VIPCardDataTable();
			this.Adapter.Fill(hLShop_VIPCardDataTable);
			return hLShop_VIPCardDataTable;
		}
		[DataObjectMethod(DataObjectMethodType.Select, false), HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual S_VIPCard.HLShop_VIPCardDataTable GetSingleVIPCardByID(int CardID)
		{
			this.Adapter.SelectCommand = this.CommandCollection[2];
			this.Adapter.SelectCommand.Parameters[0].Value = CardID;
			S_VIPCard.HLShop_VIPCardDataTable hLShop_VIPCardDataTable = new S_VIPCard.HLShop_VIPCardDataTable();
			this.Adapter.Fill(hLShop_VIPCardDataTable);
			return hLShop_VIPCardDataTable;
		}
		[DataObjectMethod(DataObjectMethodType.Select, false), HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual S_VIPCard.HLShop_VIPCardDataTable GetVIPCardByOwerID(int? ShopOwnerID)
		{
			this.Adapter.SelectCommand = this.CommandCollection[3];
			if (ShopOwnerID.HasValue)
			{
				this.Adapter.SelectCommand.Parameters[0].Value = ShopOwnerID.Value;
			}
			else
			{
				this.Adapter.SelectCommand.Parameters[0].Value = System.DBNull.Value;
			}
			S_VIPCard.HLShop_VIPCardDataTable hLShop_VIPCardDataTable = new S_VIPCard.HLShop_VIPCardDataTable();
			this.Adapter.Fill(hLShop_VIPCardDataTable);
			return hLShop_VIPCardDataTable;
		}
		[DataObjectMethod(DataObjectMethodType.Select, false), HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual S_VIPCard.HLShop_VIPCardDataTable GetVIPCardByShopID(int? ShopID)
		{
			this.Adapter.SelectCommand = this.CommandCollection[4];
			if (ShopID.HasValue)
			{
				this.Adapter.SelectCommand.Parameters[0].Value = ShopID.Value;
			}
			else
			{
				this.Adapter.SelectCommand.Parameters[0].Value = System.DBNull.Value;
			}
			S_VIPCard.HLShop_VIPCardDataTable hLShop_VIPCardDataTable = new S_VIPCard.HLShop_VIPCardDataTable();
			this.Adapter.Fill(hLShop_VIPCardDataTable);
			return hLShop_VIPCardDataTable;
		}
		[DataObjectMethod(DataObjectMethodType.Select, false), HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual S_VIPCard.HLShop_VIPCardDataTable GetVIPCardByUserNameShopName(string username, string shopname)
		{
			this.Adapter.SelectCommand = this.CommandCollection[5];
			if (username == null)
			{
				this.Adapter.SelectCommand.Parameters[1].Value = System.DBNull.Value;
			}
			else
			{
				this.Adapter.SelectCommand.Parameters[1].Value = username;
			}
			if (shopname == null)
			{
				this.Adapter.SelectCommand.Parameters[2].Value = System.DBNull.Value;
			}
			else
			{
				this.Adapter.SelectCommand.Parameters[2].Value = shopname;
			}
			S_VIPCard.HLShop_VIPCardDataTable hLShop_VIPCardDataTable = new S_VIPCard.HLShop_VIPCardDataTable();
			this.Adapter.Fill(hLShop_VIPCardDataTable);
			return hLShop_VIPCardDataTable;
		}
		[HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual int Update(S_VIPCard.HLShop_VIPCardDataTable dataTable)
		{
			return this.Adapter.Update(dataTable);
		}
		[HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual int Update(S_VIPCard dataSet)
		{
			return this.Adapter.Update(dataSet, "HLShop_VIPCard");
		}
		[HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual int Update(DataRow dataRow)
		{
			return this.Adapter.Update(new DataRow[]
			{
				dataRow
			});
		}
		[HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual int Update(DataRow[] dataRows)
		{
			return this.Adapter.Update(dataRows);
		}
		[DataObjectMethod(DataObjectMethodType.Delete, false), HelpKeyword("vs.data.TableAdapter"), System.Diagnostics.DebuggerNonUserCode]
		public virtual int DeleteVIPCard(int card_id)
		{
			SqlCommand sqlCommand = this.CommandCollection[1];
			sqlCommand.Parameters[0].Value = card_id;
			ConnectionState state = sqlCommand.Connection.State;
			if ((sqlCommand.Connection.State & ConnectionState.Open) != ConnectionState.Open)
			{
				sqlCommand.Connection.Open();
			}
			int result;
			try
			{
				result = sqlCommand.ExecuteNonQuery();
			}
			finally
			{
				if (state == ConnectionState.Closed)
				{
					sqlCommand.Connection.Close();
				}
			}
			return result;
		}
	}
}
